package com.gsafety.wellsfort.domain.vo;

import com.gsafety.wellsfort.domain.vo.security.IndexCourseVO;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

@Data
public class StudyingDataVO {
    @ApiModelProperty(value = "课程列表")
    private List<IndexCourseVO> courseList;
    @ApiModelProperty(value = "作业列表")
    private List<IndexCourseVO> workList;
    @ApiModelProperty(value = "考试列表")
    private List<IndexCourseVO> examList;

    public void addCourse(IndexCourseVO indexCourseVO) {
        if (courseList == null) {
            courseList = new ArrayList<>();
        }
        this.courseList.add(indexCourseVO);
    }

    public void addWork(IndexCourseVO indexCourseVO) {
        if (workList == null) {
            this.workList = new ArrayList<>();
        }
        this.workList.add(indexCourseVO);
    }

    public void addExam(IndexCourseVO indexCourseVO) {
        if (examList == null) {
            this.examList = new ArrayList<>();
        }
        this.examList.add(indexCourseVO);
    }
}
